#include <WdpiEngine>
#include <WdpiService>

// protocol parser class
class MyProtocolAnalyser : public wdpi::TcpListener, public wdpi::AppPlugin 
{
public:
	MyProtocolAnalyser();
	virtual ~MyProtocolAnalyser();

	// implementation wdpi::AppPlugin interface 
	virtual bool onInit(wdpi::ModuleTransfer* transfer);	
	virtual bool onUninit();
	virtual void onGetDataServiceList(wdpi::DataServiceTypeVector& dataServiceList);		
	virtual void onGetFilterRule(wdpi::FilterRule& filterRule);

	// implementation TcpListener interface
	virtual int32 onTcpPacket(const wdpi::packet::PacketReference& pktRef);
	virtual int32 onTcpSession(const wdpi::packet::PacketReference& pktRef, const wdpi::TcpSession& tcpSession);

private:
	wdpi::ModuleTransfer* m_transfer;
};

